import pytest
import time
from selenium import webdriver
from selenium.webdriver.common.by import By
from duxiaoman import  Test
@pytest.fixture(params=['https://www.baidu.com','https://www.jingdong.com','http://www.taobao.com'])
def preopen(request):
    url=request.param
    driver=webdriver.Chrome()
    driver.get(url)
    driver.maximize_window()
    yield driver
    driver.close()

@pytest.mark.parametrize("username,password",[["admin","admin123"],["guest","guest123"],["user","user123"]])
def test_login(username,password,preopen):
    print(username,password)


